package com.gasolinator.a.app;

import android.content.Context;
import android.graphics.drawable.Drawable;
import com.gasolinator.a.R;

public class GasolinatorTypes
{
  public static final byte TYPE_ALCAMPO = 9;
  public static final byte TYPE_BP = 8;
  public static final byte TYPE_CAMPSA = 4;
  public static final byte TYPE_CARREFOUR = 11;
  public static final byte TYPE_CEPSA = 2;
  public static final byte TYPE_EROSKI = 10;
  public static final byte TYPE_ESSO = 6;
  public static final byte TYPE_GALP = 7;
  public static final byte TYPE_MEROIL = 12;
  public static final byte TYPE_OTHER = 0;
  public static final byte TYPE_PETRONOR = 5;
  public static final byte TYPE_REPSOL = 1;
  public static final byte TYPE_SHELL = 3;

  private static Drawable alcampo;
  private static Drawable bp;
  private static Drawable campsa;
  private static Drawable carrefour;
  private static Drawable cepsa;
  private static Drawable eroski;
  private static Drawable esso;
  private static Drawable galp;
  private static Drawable generic;
  private static Drawable meroil;
  private static Drawable petronor;
  private static Drawable repsol;
  private static Drawable shell;

  public GasolinatorTypes(Context paramContext)
  {
    generic = paramContext.getResources().getDrawable(R.drawable.generic);
    repsol = paramContext.getResources().getDrawable(R.drawable.repsol);
    cepsa = paramContext.getResources().getDrawable(R.drawable.cepsa);
    bp = paramContext.getResources().getDrawable(R.drawable.bp);
    shell = paramContext.getResources().getDrawable(R.drawable.shell);
    campsa = paramContext.getResources().getDrawable(R.drawable.campsa);
    petronor = paramContext.getResources().getDrawable(R.drawable.petronor);
    esso = paramContext.getResources().getDrawable(R.drawable.esso);
    galp = paramContext.getResources().getDrawable(R.drawable.galp);
    alcampo = paramContext.getResources().getDrawable(R.drawable.alcampo);
    eroski = paramContext.getResources().getDrawable(R.drawable.eroski);
    carrefour = paramContext.getResources().getDrawable(R.drawable.carrefour);
    meroil = paramContext.getResources().getDrawable(R.drawable.meroil);
  }

  public static int getImageResource(byte paramByte)
  {

      int i;
      switch(paramByte) {
          case 1:i=R.drawable.repsol;break;
          case 2:i=R.drawable.cepsa;break;
          case 3:i=R.drawable.shell;break;
          case 4:i=R.drawable.campsa;break;
          case 5:i=R.drawable.petronor;break;
          case 6:i=R.drawable.esso;break;
          case 7:i=R.drawable.galp;break;
          case 8:i=R.drawable.bp;break;
          case 9:i=R.drawable.alcampo;break;
          case 10:i=R.drawable.eroski;break;
          case 11:i=R.drawable.carrefour;break;
          case 12:i=R.drawable.meroil;break;
          default: i=R.drawable.generic;
      }
      return i;
//
  }

  public Drawable getMarker(byte paramByte)
  {
    Drawable localDrawable = generic;

      switch(paramByte) {
          case 1:localDrawable = repsol;break;
          case 2:localDrawable = cepsa;break;
          case 3:localDrawable = shell;break;
          case 4:localDrawable = campsa;break;
          case 5:localDrawable = petronor;break;
          case 6:localDrawable = esso;break;
          case 7:localDrawable = galp;break;
          case 8:localDrawable = bp;break;
          case 9:localDrawable = alcampo;break;
          case 10:localDrawable = eroski;break;
          case 11:localDrawable = carrefour;break;
          case 12:localDrawable = meroil;break;
          default:
      }
      return localDrawable;

  }

    public static byte getResourceByName(String rotulo) {
        rotulo=rotulo.toLowerCase();
        if (rotulo.contains("alcampo")) return TYPE_ALCAMPO;
        if (rotulo.contains("bp")) return TYPE_BP;
        if (rotulo.contains("campsa")) return TYPE_CAMPSA;
        if (rotulo.contains("carrefour")) return TYPE_CARREFOUR;
        if (rotulo.contains("cepsa")) return TYPE_CEPSA;
        if (rotulo.contains("eroski")) return TYPE_EROSKI;
        if (rotulo.contains("esso")) return TYPE_ESSO;
        if (rotulo.contains("galp")) return TYPE_GALP;
        if (rotulo.contains("meroil")) return TYPE_MEROIL;
        if (rotulo.contains("petronor")) return TYPE_PETRONOR;
        if (rotulo.contains("repsol")) return TYPE_REPSOL;
        if (rotulo.contains("shell")) return TYPE_SHELL;
        return TYPE_OTHER;
    }
}

/* Location:           /home/fjhidalgo/Escritorio/gasolinator_flips/classes.dex.dex2jar.jar
 * Qualified Name:     com.gasolinator.a.app.GasolinatorTypes
 * JD-Core Version:    0.6.0
 */